fs: ubifs: Fix UBIFS decompression on 64 bit
authorPaul Davey <[email protected]>
Mon, 5 Nov 2018 05:09:29 +0000 (18:09 +1300)
committerHeiko Schocher <[email protected]>
Wed, 7 Nov 2018 07:49:27 +0000 (08:49 +0100)
commite4aa10ba5770fc391bf8a4b00c131353901704e7
tree10771073ad0c27e127f55072065db6390e3dd5fc
parentdd610e616cceda16a81dfa6f9a134877f783548c
fs: ubifs: Fix UBIFS decompression on 64 bit

Add local size_t variable to crypto_comp_decompress as intermediate
storage for destination length to avoid memory corruption and incorrect
results on 64 bit targets.

This is what linux does for the various lz compression implementations.

Signed-off-by: Paul Davey <[email protected]>
Cc: Heiko Schocher <[email protected]>
Tested-by: Heiko Schocher <[email protected]>
fs/ubifs/ubifs.c